#ifndef MODEL_H
#define MODEL_H

#include "Config/Export.h"
#include "Core/IResource.h"
#include "Maths/TVector3.h"

namespace blue {

template <typename Type>
struct TBufferData
{
    Type *data;
    int size;
};

typedef TBufferData<float> dataf;
typedef TBufferData<int> datai;

enum dataf_t
{
  DATAF_POSITION = 0,
  DATAF_TEXTURE,
  DATAF_NORMAL
};

class SHARED Model : public IResource
{
    public:

        Model(const dataf &pos, const dataf &tex, const dataf &nor, const datai &indices, const char *name);
        ~Model();

        const dataf &getBuffer(dataf_t type) const;
        const datai &getIndexBuffer() const;

    private:

        dataf _pos, _tex, _nor;
        datai _indices;

};

}

#endif
